package org.aj.common.web.file.config;

import org.springframework.boot.context.properties.ConfigurationProperties;

/**
 * description 配置分布式文件系统相关配置
 *
 * @author jcj
 * date 2022/6/16 17:57
 */
@ConfigurationProperties(prefix = "aj.distribute.filesystem.server")
public class DistributeFileServerProperties {

    /**
     * 主机地址
     */
    private String host;

    /**
     * 端口号
     */
    private Integer port;

    /**
     * 是否开启ssl
     */
    private Boolean ssl;

    /**
     * 用户名
     */
    private String username;

    /**
     * 密码
     */
    private String password;

    /**
     * 目录 存储桶名称
     */
    private String dir;

    /**
     * 定义给调用者返回此资源的根路径 即 协议+ip(域名）+端口号
     * 当然也可以不配置 主要是为了兼容之前的代码
     * 之前获得构建图片的绝对路径通过此值获取
     */
    private String urlRoot;


    public Integer getPort() {
        return port;
    }

    public void setPort(Integer port) {
        this.port = port;
    }

    public Boolean getSsl() {
        return ssl;
    }

    public void setSsl(Boolean ssl) {
        this.ssl = ssl;
    }

    public String getUsername() {
        return username;
    }

    public void setUsername(String username) {
        this.username = username;
    }

    public String getPassword() {
        return password;
    }

    public void setPassword(String password) {
        this.password = password;
    }

    public String getDir() {
        return dir;
    }

    public void setDir(String dir) {
        this.dir = dir;
    }

    public String getUrlRoot() {
        return urlRoot;
    }

    public void setUrlRoot(String urlRoot) {
        this.urlRoot = urlRoot;
    }

    public String getHost() {
        return host;
    }

    public void setHost(String host) {
        this.host = host;
    }
}
